﻿using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace Gx.Model.Entity
{
    [Table("LK_Company")]
    public class LKCompany
    {
        [Key]
        private int _id;
        /// <summary>
        /// Id
        /// </summary>
        [Column("Id")]
        public int Id
        {
            get
            {
                return _id;
            }
            set { _id = value; }
        }


        private string _companyCode;
        /// <summary>
        /// 公司编码
        /// </summary>
        [Column("CompanyCode")]
        public string CompanyCode
        {
            get
            {
                if (string.IsNullOrWhiteSpace(_companyCode))
                    _companyCode = string.Empty;
                return _companyCode;
            }
            set { _companyCode = value; }
        }


        private string _companyName;
        /// <summary>
        /// 公司名称
        /// </summary>
        [Column("CompanyName")]
        public string CompanyName
        {
            get
            {
                if (string.IsNullOrWhiteSpace(_companyName))
                    _companyName = string.Empty;
                return _companyName;
            }
            set { _companyName = value; }
        }


        private string _address;
        /// <summary>
        /// 地址
        /// </summary>
        [Column("Address")]
        public string Address
        {
            get
            {
                if (string.IsNullOrWhiteSpace(_address))
                    _address = string.Empty;
                return _address;
            }
            set { _address = value; }
        }


        private string _moblie;
        /// <summary>
        /// 联系电话
        /// </summary>
        [Column("Moblie")]
        public string Moblie
        {
            get
            {
                if (string.IsNullOrWhiteSpace(_moblie))
                    _moblie = string.Empty;
                return _moblie;
            }
            set { _moblie = value; }
        }


        private string _phone;
        /// <summary>
        /// 座机
        /// </summary>
        [Column("Phone")]
        public string Phone
        {
            get
            {
                if (string.IsNullOrWhiteSpace(_phone))
                    _phone = string.Empty;
                return _phone;
            }
            set { _phone = value; }
        }


        private bool _isDeleted;
        /// <summary>
        /// 是否删除
        /// </summary>
        [Column("IsDeleted")]
        public bool IsDeleted
        {
            get
            {
                return _isDeleted;
            }
            set { _isDeleted = value; }
        }


        private System.DateTime _createTime;
        /// <summary>
        /// 创建时间
        /// </summary>
        [Column("CreateTime")]
        public System.DateTime CreateTime
        {
            get
            {
                if (_createTime == DateTime.MinValue)
                {
                    return DateTime.Parse("1911-01-01");
                }
                return _createTime;
            }
            set { _createTime = value; }
        }


        private int _createUserId;
        /// <summary>
        /// 创建人id
        /// </summary>
        [Column("CreateUserId")]
        public int CreateUserId
        {
            get
            {
                return _createUserId;
            }
            set { _createUserId = value; }
        }


        private string _createUser;
        /// <summary>
        /// 创建人
        /// </summary>
        [Column("CreateUser")]
        public string CreateUser
        {
            get
            {
                if (string.IsNullOrWhiteSpace(_createUser))
                    _createUser = string.Empty;
                return _createUser;
            }
            set { _createUser = value; }
        }


    }
}

